import React, { Component } from 'react'

export default class DishTop extends Component {
    render() {
        let {list}=this.props;
        return (
            <div>
                <span onClick={()=>{
                      this.props.selectCate("");
                }}>全部  | </span>
                {list.map((v,i)=>{
                   return  <span key={i}><span key={i} onClick={()=>{
                       this.props.selectCate(v);
                   }}>{v} </span> | </span>
                })}
            </div>
        )
    }
}
